package com.order.service.impl;

import com.order.dao.DeskDao;
import com.order.pojo.Desk;
import com.order.service.DeskService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class DeskServiceImpl implements DeskService {
    @Autowired
    private DeskDao deskDao;
    @Override
    public Integer insertDesk(Desk desk) {
        return deskDao.insertDesk(desk);
    }

    @Override
    public Boolean setFull(Integer id) {
        return deskDao.setFull(id);
    }

    @Override
    public Boolean setEmpty(Integer id) {
        return deskDao.setEmpty(id);
    }

    @Override
    public Integer countDesk() {
        return deskDao.countDesk();
    }

    @Override
    public Integer countEmptyDesk() {
        return deskDao.countEmptyDesk();
    }

    @Override
    public List<Desk> findDesks() {
        return deskDao.findDesks();
    }

    @Override
    public List<Desk> findEmptyDesks() {
        return deskDao.findEmptyDesks();
    }
}
